<html>
<head>
    <link rel="stylesheet" type="text/css" href="jquery.jcrop.css"/> 
    <link rel="stylesheet" type="text/css" href="nise.css"/> 
    <script type="text/javascript" src="jquery.js"></script>
    <script type="text/javascript" src="jquery.jcrop.nise.js"></script>
    <script type="text/javascript" src="jquery.form.js"></script>
    <script type="text/javascript" src="nise.js"></script>
</head>
<body>
    <!-- Header -->
    <table id="top"><tr>
        <td class="left"><img id="logo" src="logo.png"/><br/></td>
        <td>
        <!-- Search Bar -->
            <table>
                <tr>
                    <td>Enter image address</td>
                    <td>Upload an image</td>
                    <td>Show demo</td>
                    <!--
                    <td>Show random images</td>
                    -->
                </tr>
                <tr>
                    <td>
                        <form class="search">
                        <input id="query_url"></input>
                        <button id="search_url">Search</button>
                        <span>or</span>
                        </form>
                    </td>
                    <td>
                       <form id="upload_form" class="search" action="/search/upload" enctype="multipart/form-data" method="POST">
                       <input type="hidden" id="form_threshold" name="threshold" value=""/>
                       <input type="hidden" id="form_expansion" name="expansion" value=""/>
                       <input type="hidden" id="form_batch" name="batch" value=""/>
                       <input type="hidden" id="form_size" name="size" value=""/>
                       <input type="hidden" id="form_offset" name="page_offset" value="0"/>
                       <input type="hidden" id="form_count" name="page_count" value="20"/>
                       <input type="hidden" id="form_time" name="time_limit" value="1000"/>
                       <input id="upload_file" type="file" name="upload" />
                       <input id="upload_submit" type="submit" value="Upload"/>
                       <span>or</span>
                       </form>
                     </td>
                     <td>
                       <form class="search">
                           <button id="show_demo">Demo</button>
                       </form>
                     </td>
                     <!--
                     <td>
                       <form class="search">
                           <button id="search_random">Random</button>
                       </form>
                     </td>
                     -->
                </tr>
            </table>
       </td>
    </tr></table>
    <!-- Header done -->
    <table><tr>
        <td valign="top" class="left">
            <div class="summary">Query Info</div>
            <div id="query">
                <img id="crop" src=""/>
                <button id="docrop" style="width:50px">Crop</button>
                <button id="docut" style="width:50px">Cut</button>
            </div>
            <div id="options_toggle" class="toggle">Search Options</div>
            <div id="options" class="toggled">
                <table class="option_table">
                        <!--
                <tr><td>
                Similarity threshold:
                </td></tr>
                <tr><td>
                <select id="threshold" class="resubmit" name="threshold">
                    <option value="3">tight</option>
                    <option value="4" selected>loose</option>
                </select>

                </td></tr>
                -->
                <tr><td>
                Result expansion:
                </td></tr>
                <tr><td>
                <select id="result_expansion" class="resubmit" name="expansion">
                    <option value="0">no</option>
                    <option value="1" selected>yes</option>
                </select>
                </td></tr>
                <tr><td>
                Incremental search:
                </td></tr>
                <tr><td>
                <select id="result_batch" class="resubmit" name="batch">
                    <option value="0" selected>yes</option>
                    <option value="1">no</option>
                </select>
                </td></tr>
                <tr><td>
                Results per page:
                </td></tr>
                <tr><td>
                <select id="results_per_page" class="refresh">
                    <option value="20" selected>20</option>
                    <option value="50">50</option>
                    <option value="100">100</option>
                </select>
                </td></tr>
                <!--
                <tr><td>
                Size filter:
                </td></tr>
                <tr><td>
                <select id="size_select"class="resubmit">
                    <option value="0" selected>all</option>
                    <option value="1">small</option>
                    <option value="2">medium</option>
                    <option value="3">large</option>
                </select>
                </td></tr>
                -->
                <tr><td>
                Time limit:
                </td></tr>
                <tr><td>
                <select id="time_limit">
                    <option value="100">0.1s</option>
                    <option value="200">0.2s</option>
                    <option value="500">0.5s</option>
                    <option value="1000" selected>1s</option>
                    <option value="2000">2s</option>
                    <option value="5000">5s</option>
                </select>
                </td></tr>
                </table>
            </div>
            <div id="advanced_toggle" class="toggle">Advanced</div>
            <div id="advanced" class="toggled">
                <table class="option_table">
                <tr><td>
                Current Session
                </td></tr>
                <tr><td>
                <input id="current_session" style="width:60px"/>
                <!--
                <button id="copy_session">Copy</button><br/>
                -->
                </td></tr>
                <tr><td>
                Current SHA1
                </td></tr>
                <tr><td>
                <input id="current_sha1" style="width:60px"/>
                <!--
                <button id="copy_sha1">Copy</button><br/>
                -->
                </td></tr>
                <tr><td>
                Recover Session
                </td></tr>
                <tr><td>
                <input id="session_key" style="width:60px"/>
                <button id="recover_session">Get</button><br/>
                </td></tr>
                <tr><td>
                Search by SHA1
                </td></tr>
                <tr><td>
                <input id="query_sha1" style="width:60px"/>
                <button id="search_sha1">Get</button><br/>
                </td></tr>
                <tr><td>
                System Statistics
                </td></tr>
                <tr><td>
                <button id="statistics">Get</button><br/>
                </td></tr>
                </table>
            </div>
            <div id="history_toggle" class="toggle">Search History</div>
            <div id="history" class="toggled">
                <a id="clear_history">Clear History</a>
                <div id="history_list">
                </div>
            </div>
        </td>
        <td valign="top" id="right"><table>
                <tr><td><div class="summary"><span id="total"></span><span id="viewing"></span></div></td></tr>
                <tr><td><div id="results"></div></td></tr>
            <tr><td><div class="summary" id="index"></div></td></tr>
        </table></td>
    </tr></table>
    <div id="bottom">
        We currently index 30 million Flickr images + 30 million product images.
        <a href="simigle.pdf">Technical details.</a><br/>
        Simigle Image Search Engine, A <a href="http://www.cs.princeton.edu/cass">CASS</a> Project. Copyright 2009,2010 <a href="http://www.cs.princeton.edu/~wdong">Wei Dong</a></div>
</body>
</html>

